package cn.mw.cmdb.entity.instanceToPo;

import cn.mw.cmdb.entity.PropertyTypeString;
import cn.mw.cmdb.entity.PropertyTypeTime;
import cn.mw.components.mongodb.anno.AutoId;
import cn.mw.components.mongodb.anno.CMDBProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.Date;

@Data
@Document("mw_cmdbmd_instance_health_history_info")
@Schema(description = "实例健康度历史")
public class InstanceHealthHistoryDTO {

    @CMDBProperty(searchType = PropertyTypeString.ID, searchPrefix = "_")
    @AutoId
    @Schema(description = "id")
    private String id;

    @Schema(description = "实例ID")
    @CMDBProperty(searchType = PropertyTypeString.ID, keywordSearch = true)
    private String instanceId;

    @Schema(description = "健康度分组")
    @CMDBProperty(searchType = PropertyTypeString.ID, keywordSearch = true)
    private Double healthCount;

    @CMDBProperty(searchType = PropertyTypeTime.ID)
    @Schema(description = "更新时间")
    protected Date updateTime;
}
